<?php get_header(); ?>
<?php //top_posts(); ?>
<div id="tabsbar">
	<div id="tabs">
		<ul>
			<li id="hightlight">Posts</li>
			<li id="searchbar">
                <form id="searchform" method="get" action="<?php bloginfo('home'); ?>">
                	<input id="s" type="text" onblur="if(this.value=='') this.value='Search Blog...'" onfocus="if(this.value=='Search Blog...') this.value=''" name="s" value="Search Blog..."/>
                	<input type="submit" value="Search"/>
                </form>
            </li>
			<li id="rss"><a href="<?php bloginfo('rss2_url'); ?>">Subscribe to the feed</a></li>
		</ul>
	</div>
	<div class="clear"></div>
</div>

<div id="container">
	<div id="main">
		<div id="innerMain">
		<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
		<div <?php post_class() ?> id="post-<?php the_ID(); ?>">
			<h1 class="storytitle">
				<a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a>
				<span class="edit"><?php edit_post_link(__('Edit')); ?></span>
			</h1>
			
			<div class="meta">
				<?php _e("Filed under:"); ?> <?php the_category(', '); ?> by <?php the_author(); ?> on <?php post_time(); ?>.
			</div>
		
			<div class="maincontent">
				<?php the_content(__('See more about this post')); ?>
			</div>
		
			<div class="post-info">
				<div class="comments">
					<?php //wp_link_pages(); ?>
					<?php comments_popup_link(__('0'), __('1'), __('%')); ?>
				</div>
				<div class="tags">
					<?php the_tags('', '', ''); ?>
				</div>
			</div>
		</div>
		<?php comments_template(); // Get wp-comments.php template ?>
		
		<?php endwhile; else: ?>
		<p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
		<?php endif; ?>
		
		<div id="pagination">
			<?php if (function_exists('wp_pagenavi') && is_home() ) : ?>
				<?php wp_pagenavi(); ?>
			<?php else : ?>
				<span class="newer"><?php previous_posts_link('Newer Entries'); ?></span>
				<span class="older"><?php next_posts_link('Older Entries'); ?></span>
			<?php endif; ?>
		</div>
		</div>
	</div>
	
	<div id="sidebar">
		<?php get_sidebar(); ?>
        <?php include (TEMPLATEPATH . '/sidebar3.php'); ?>
        <?php include (TEMPLATEPATH . '/sidebar2.php'); ?>
	</div>
	<div class="clear"></div>
</div>
<?php get_footer(); ?>
